import request from '@/utils/request'

// 查询device列表
export function list(pageSize, pageNum) {
  const data = {
    pageSize,
    pageNum,
  }
  return request({
    url: '/separate/user/list',
    method: 'get',
    params: data
  })
}

// 新增device
export function add(data) {

  return request({
    url: '/separate/user',
    method: 'post',
    params: data
  })
}

// 新增device
export function bind(data) {
  return request({
    url: '/separate/user/bind',
    method: 'post',
    params: data
  })
}

// 删除device
export function del(id) {
  return request({
    url: '/separate/user/' + id,
    method: 'DELETE',
  })
}
// 修改device
export function update(data) {

  return request({
    url: '/separate/user',
    method: 'put',
    params: data
  })
}
// 查询device详情
export function detail(id) {
  return request({
    url: '/separate/user/' + id,
    method: 'get',
  })
}

// 查询device详情
export function getlbk(lbnkProv, lbnkCity, bnkCd, banktype) {
  return request({
    url: '/separate/user/getlbk',
    method: 'get',
    params: {
      banktype: banktype,
      lbnkProv: lbnkProv,
      lbnkCity: lbnkCity,
      bnkCd: bnkCd
    }
  })
}

// 搜索device
export function inquire(data) {
  return request({
    url: '/separate/user/list',
    method: 'get',
    params: data
  })
}